/**
 * jims
 */
package com.jims.master.modules.patient.myFriend.service;

import com.jims.master.common.persistence.Page;
import com.jims.master.common.service.CrudService;
import com.jims.master.modules.patient.myFriend.dao.SysUserFriendDao;
import com.jims.master.modules.patient.myFriend.entity.SysUserFriend;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import java.util.List;

/**
 * 建立好友关系Service
 * @author 王永强
 * @version 2017-07-03
 */
@Service
@Transactional(readOnly = true)
public class SysUserFriendService extends CrudService<SysUserFriendDao, SysUserFriend> {

	@Override
    public SysUserFriend get(String id) {
		return super.get(id);
	}
	
	@Override
    public List<SysUserFriend> findList(SysUserFriend sysUserFriend) {
		return super.findList(sysUserFriend);
	}
	
	@Override
    public Page<SysUserFriend> findPage(Page<SysUserFriend> page, SysUserFriend sysUserFriend) {
		return super.findPage(page, sysUserFriend);
	}
	
	@Override
    @Transactional(readOnly = false)
	public int save(SysUserFriend sysUserFriend) {
		return super.save(sysUserFriend);
	}
	
	@Override
    @Transactional(readOnly = false)
	public int delete(SysUserFriend sysUserFriend) {
		return super.delete(sysUserFriend);
	}

	/**
	 * 查找好友对象
	 * @param  sysUserFriend
	 * @return SysUserFriend
	 */
	public SysUserFriend findByFaccid(SysUserFriend sysUserFriend){
		return this.dao.findByFaccid(sysUserFriend);}
}